<template>
  <div>
    <film-swiper>
      <div class="swiper-slide" v-for="item in bannerList" :key="item.bannerId">
        <img :src="item.imgUrl" alt="" />
      </div>
    </film-swiper>
    <film-header></film-header>
    <router-view></router-view>
  </div>
</template>
<script>
import filmHeader from "@/views/film/FilmHeader";
import filmSwiper from "@/views/film/FilmSwiper";
import http from "@/utils/http.js";
export default {
  components: { filmHeader, filmSwiper },
  data() {
    return {
      bannerList: [],
    };
  },
  mounted() {
    http({
      url: "/gateway?type=2&cityId=440100&k=7138024",
      headers: {
        "X-Host": "mall.cfg.common-banner",
      },
    }).then((res) => {
      console.log(res);
      this.bannerList = res.data.data;
    });
  },
};
</script>

<style scoped lang='scss'>
.swiper-slide {
  img {
    width: 100%;
  }
}
</style>
